﻿using System.Windows;
using System.Windows.Controls;
using System.Windows.Media;

namespace TraceView.UI.CustomControls
{
    public class ImageRadioButton :RadioButton
    {
        public static readonly DependencyProperty DefaultImageSourceProperty =
            DependencyProperty.Register("DefaultImageSource", typeof(ImageSource), typeof(ImageRadioButton),
                                        new UIPropertyMetadata());


        public static readonly DependencyProperty MouseOverImageSourceProperty =
            DependencyProperty.Register("MouseOverImageSource", typeof(ImageSource), typeof(ImageRadioButton),
                                        new UIPropertyMetadata());


        static ImageRadioButton()
        {
            DefaultStyleKeyProperty.OverrideMetadata(typeof(ImageRadioButton),
                                                     new FrameworkPropertyMetadata(typeof(ImageRadioButton)));
        }

        public ImageSource MouseOverImageSource
        {
            get { return (ImageSource) GetValue(MouseOverImageSourceProperty); }
            set { SetValue(MouseOverImageSourceProperty, value); }
        }

        public ImageSource DefaultImageSource
        {
            get { return (ImageSource) GetValue(DefaultImageSourceProperty); }
            set { SetValue(DefaultImageSourceProperty, value); }
        }
    }
}